const {loopPrimaryDirs,diffDirs} = require('./utils/diff')
const {ignoreDiffDirectory,ignoreDiffFile} = require('./config')
const {i18Diff} = require('./utils/i18')

// 不需要被diff的文件或文件夹
const nodeDiffDirectory = ['.svn','.hbuilderx','node_modules','unpackage','打包配置文件','nativeplugins']
const nodeDiffFile = ['.env.development','.env.production','env.ts','pages.json','manifest.json','package.json','package-lock.json','tsconfig.json']
const projectPath = `D:\\vscodeProject\\`
const diff = () => {
	let newFilePath = projectPath +'吉信\\吉信超A小程序（用户端v3）\\src'
	let oldFilePath = projectPath +'sass\\ISHOP用户端-Vue3'
	let oldFilePathList = []
	
	// 获取到sass用户端下需要diff的文件路径列表
	loopPrimaryDirs(oldFilePath,oldFilePathList,nodeDiffDirectory,nodeDiffFile)
	oldFilePathList.forEach(item => {
		diffDirs(item,oldFilePath,newFilePath,ignoreDiffDirectory,ignoreDiffFile)
	})
	i18Diff(true)
	
}

diff()